import * as api from './util';


// 客户列表
export const getCustomList = function (postbody) {
  return api.post('/applets/provider/customUser/list', postbody);
}

// 获取客户订单列表
export const findOrderListByCustomId = function (params) {
  return api.get('/applets/provider/order/findOrderListByCustomId', params);
}

// 获取客户详情
export const getCustomUser = function (postbody) {
  return api.post('/applets/provider/customUser/get', postbody);
}

// 获取客户联系人
export const getCustomerContact = function (postbody) {
  return api.post('/applets/provider/customAccount/allList', postbody);
}

// 获取客户商品订单
export const findOrderListByUserId = function (params) {
  return api.get('/applets/provider/order/findOrderListByUserId', params);
}

//历史记录
export function getRecentSearchContacts() {
  return api.get('/applets/provider/custom/searchList');
};
//添加搜索记录
export function addSearchRecord(postbody) {
  return api.post('/applets/provider/custom/addSearchRecords', postbody);
};
//清空历史记录
export function clearSearchRecord() {
  return api.post('/applets/provider/custom/deleteHistory', {});
};